#ifndef CANDLESTICK_H
#define CANDLESTICK_H

#include <QGraphicsItem>

class CandleStick : public QGraphicsItem
{
public:
    CandleStick(int open, int close, int high, int low);

    QRectF boundingRect() const;
    QPainterPath shape() const;
    void paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget *widget);

protected:
    //void mouseHoverEvent(QGraphicsSceneMouseEvent *event);

private:
    int StickLength;
    int RealBody;
    int ShadowUp;
    int ShadowLow;
    QColor color;
};

typedef struct CANDLESTRICKCHART
{
public:
    CandleStick *candlestick;
    CandleStick *candlestick2;
private:
    int StickLength;
    int RealBody;
    int ShadowUp;
    int ShadowLow;

} CANDLESTRICKCHART;

#endif // CANDLESTICK_H
